package multithreading.threadd.commonmethod;

public class Sleep {
    public static void main(String[] args) throws InterruptedException {

        for (int i = 0; i < 5; i++) {
            System.out.println(i);
            if (i == 3) {
                Thread.sleep(3000);
            }
        }
            Thread A=new MyDemo1("一号");
        A.start();
        A.join();
        Thread b=new MyDemo1("二号");
        b.start();
        b.join();
    }
}
